<template>
  <div class="app-container">
    <h1>App 根组件</h1>
    <hr />
    <Test info="你好！" v-if="flag = !flag">Toggle Flag</Test>
    <hr/>
    <div class="box">
      <Left></Left>
      <Right></Right>
    </div>

  </div>
</template>

<script>
import Left from '@/components/Left.vue'
import Right from '@/components/Right.vue'
import Test from '@/components/Test.vue'
import Count from "./components/Count";

export default {
  data() {
    return {
      flag: true
    }
  },
  methods: {
    // 获取子组件传递过来的数据
    getNewCount(val) {
      console.log('numchange 事件被触发了！', val)
      this.countFromSon = val
    }
  },
  //私有子组件
  components: {
    Count,
    Left,
    Right,
    Test
  }
}
</script>

<style lang="less">
.app-container {
  padding: 1px 20px 20px;
  background-color: #efefef;
}
.box {
  display: flex;
}
</style>
